//
//  FindWithConditionTableViewCell.m
//  MyYiJianKangApp
//
//  Created by 张国文 on 16/3/31.
//  Copyright © 2016年 hangzhouyijiyin. All rights reserved.
//

#import "FindWithConditionTableViewCell.h"

@implementation FindWithConditionTableViewCell

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        [self addMySubview];
    }
    return self;
}

// 构建视图
- (void)addMySubview
{
    // 条件图片
    self.findImageV = [[UIImageView alloc] initWithFrame:CGRectMake(16 * kAdjustParamater, 18 * kAdjustParamater, 17 * kAdjustParamater, 17 * kAdjustParamater)];
 //   self.findImageV.backgroundColor = [UIColor redColor];
    self.findImageV.image = [UIImage imageNamed:@"teshuxuanxiang-tianjia"];
    [self.contentView addSubview:_findImageV];
    
    // 条件查找陌生人
    self.findWithConditionLabel = [[UILabel alloc] initWithFrame:CGRectMake(self.findImageV.right + 10 * kAdjustParamater, 11 * kAdjustParamater, 120 * kAdjustParamater, 11 * kAdjustParamater)];
  //  self.findWithConditionLabel.backgroundColor = [UIColor redColor];
    self.findWithConditionLabel.text = @"按条件查找陌生人";
    self.findWithConditionLabel.font = [UIFont systemFontOfSize:13 * kAdjustParamater];
    [self.contentView addSubview:_findWithConditionLabel];
    
    // 条件
    self.conditionLabel = [[UILabel alloc] initWithFrame:CGRectMake(self.findImageV.right + 10 * kAdjustParamater, self.findWithConditionLabel.bottom + 6 * kAdjustParamater, 28 * kAdjustParamater, 11 * kAdjustParamater)];
  //  self.conditionLabel.backgroundColor = [UIColor redColor];
    self.conditionLabel.text = @"条件:";
    self.conditionLabel.font = [UIFont systemFontOfSize:12 * kAdjustParamater];
    self.conditionLabel.textColor = [[UIColor blackColor] colorWithAlphaComponent:0.4];
    [self.contentView addSubview:_conditionLabel];
    
    // 性别
    self.genderLabel = [[UILabel alloc] initWithFrame:CGRectMake(self.conditionLabel.right + 6 * kAdjustParamater, self.conditionLabel.top, 25 * kAdjustParamater, 11 * kAdjustParamater)];
  //  self.genderLabel.backgroundColor = [UIColor redColor];
    self.genderLabel.font = [UIFont systemFontOfSize:12 * kAdjustParamater];
    self.genderLabel.textColor = [[UIColor blackColor] colorWithAlphaComponent:0.4];
    self.genderLabel.textAlignment = NSTextAlignmentLeft;
    [self.contentView addSubview:_genderLabel];
    
    // 年龄
    self.ageLabel = [[UILabel alloc] initWithFrame:CGRectMake(self.genderLabel.right, self.conditionLabel.top, 50 * kAdjustParamater, 11 * kAdjustParamater)];
 //   self.ageLabel.backgroundColor = [UIColor redColor];
    self.ageLabel.font = [UIFont systemFontOfSize:12 * kAdjustParamater];
    self.ageLabel.textColor = [[UIColor blackColor] colorWithAlphaComponent:0.4];
    [self.contentView addSubview:_ageLabel];
    
}

@end
